package O3.workflow;

import java.util.Scanner;

public class IfCon {

    public static void main(String[] args) {
        int n = 70;
        if (n >= 90) {
            System.out.println("Excellent");
        }else if(n>=80) {
            System.out.println("Exciting");
        }else{
            System.out.println("Not Satisfied");
        }
        System.out.println("END");

        String s1 = "hello";
        String s2 = "HELLO".toLowerCase();
        System.out.println(s1);
        System.out.println(s2);
        if (s1 == s2) {
            System.out.println("s1 == s2");
        } else {
            System.out.println("s1 != s2");
        }

        if(s1.equals(s2)){
            System.out.println("Values equal");
        }

        Scanner scanner = new Scanner(System.in);
        System.out.print("Input Your height: ");
        double height = scanner.nextDouble();
        System.out.print("Input Your Weight: ");
        double weight = scanner.nextDouble();

        String result = bmi(weight, height);
        System.out.println(result);

    }

    private static String bmi(double weight, double height){
        double bmindex = weight / height / height;
        if(bmindex>32){
            return  "Very Fat " + bmindex;
        }else if (bmindex>28){
            return "Fat "+bmindex ;
        }else if(bmindex>25){
            return "Over Weight "+ bmindex;
        }else if(bmindex>18.5){
            return "Normal " + bmindex;
        }else{
            return "Under Weight "+ bmindex;
        }
    }

}
